<%--
  Created by IntelliJ IDEA.
  User: HUAWEI
  Date: 2021/6/8
  Time: 17:00
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java"
isELIgnored="false" %>
<html>
<head>
    <title>Title</title>
</head>
<body>
    <form action="/spring/fileUplode/uplode" enctype="multipart/form-data" method="post">
        <input type="file" name="file"/>
        <input type="submit" value="上传">
    </form>
    <!-- 需要指定enctype="multipart/form-data" 不然文件上传不了 -->
    <form action="/spring/fileDownload/down" method="post" enctype="multipart/form-data">
        <input type="file" name="file"><!-- name值需要和控制器那边（value="file"）对应 -->
        <button type="submit">下载</button>
    </form>

    <a href="/spring/fileDownload/down">下载 方式一</a>
    <a href="/spring/fileDownload/down2?file=1.jpg">下载 方式二</a>
</body>
</html>
